package com.shenmazong.servereduresume.controller;

import com.baomidou.mybatisplus.extension.service.IService;
import com.shenmazong.servereduresume.dto.TbCertificate;
import com.shenmazong.servereduresume.service.TbCertificateService;
import com.shenmazong.utils.ResultResponse;
import com.shenmazong.vo.BatchChooseIdVo;
import com.shenmazong.vo.ListParamVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 *
 */
@RestController
@RequestMapping("certificate")
public class TbCertificateController {
    @Autowired
    private TbCertificateService tbCertificateService;
    @PostMapping("findAllCertificate")
    public ResultResponse findAllCertificate(@RequestBody ListParamVo listParamVo){
        return tbCertificateService.findAllCertificate(listParamVo);
    }
    @PostMapping("saveCertificate")
    public ResultResponse saveCertificate(@RequestBody TbCertificate tbCertificate){
        return tbCertificateService.saveCertificate(tbCertificate);
    }
    @PostMapping("updateCertificate")
    public ResultResponse updateCertificate(@RequestBody TbCertificate tbCertificate){
        return tbCertificateService.updateCertificate(tbCertificate);
    }
    @PostMapping("deleteCertificate")
    public ResultResponse deleteCertificate(@RequestBody BatchChooseIdVo batchChooseIdVo){
        return tbCertificateService.deleteCertificate(batchChooseIdVo);
    }
}
